package com.blogspot.dizpers.scribendi.plugins.plugincontainer;

import java.util.Map;

import com.google.inject.AbstractModule;
import com.google.inject.Scopes;
import com.google.inject.TypeLiteral;

import com.blogspot.dizpers.scribendi.plugins.api.*;
import com.blogspot.dizpers.scribendi.plugins.plugincontainer.PluginProvider;;

public class PluginContainerModule extends AbstractModule {

	@Override
	protected void configure() {

		bind(new TypeLiteral<Map<String,IPluginContext>>() {
		})
		.toProvider(PluginProvider.<Map<String,IPluginContext>> pluginProvider());

		bind(IPluginContainer.class)
		.to(PluginContainer.class)
		.in(Scopes.SINGLETON);
	}
}